package com.joe.test_mybatis_plus.controller;

import com.joe.test_mybatis_plus.utils.MessageUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Joe
 * @description 描述
 * @time 2023/3/6 11:57
 **/
@RestController
@RequestMapping(value = "/i18")
@Api(value = "国际化接口")
public class I18Controller {

    @ApiOperation(value = "国际化异常测试",notes = "国际化异常测试")
    @RequestMapping(value = "/getI18Info",method = RequestMethod.GET)
    public String getI18Info(){
        String msg1 = MessageUtils.message("100001");
        String msg2 = MessageUtils.message("100004");
        return msg1+"\n"+msg2;
    }

    public static void main(String[] args) {
        String a = "12345678";
        System.out.println(a.length());
        String b = "一支穿云箭一志愿纯";
        System.out.println(b.length());
    }
}
